Error bound formula for the trapezoid rule